home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 1 / Cream of the Crop 1.iso / PROGRAM / DMAKE38B.ARJ / MAKEFILE < prev    next >
Text File  |  1991-03-12  |  1KB  |  78 lines

  1. #
  2. # (c) Copyright 1990 Conor P. Cahill (uunet!virtech!cpcahil).  
  3. # You may copy, distribute, and use this software as long as this
  4. # copyright statement is not removed.
  5. #
  6. #
  7. # This is the Makefile for the malloc debugging library
  8. #
  9. # $Id: Makefile,v 1.5 90/08/29 22:34:27 cpcahil Exp $
  10. #
  11. CC=cc
  12. # for System V systems use this CFLAGS
  13. #CFLAGS=-g -DSYS5
  14. # else for BSD use:
  15. #CFLAGS=-g
  16. LINT=lint
  17. SHARCMD=shar -o mallocshar -l50 -x -a -n Malloclib
  18. SHELL=/bin/sh
  19.  
  20. LIB=libmalloc.a
  21.  
  22. SRCS=    malloc.c    \
  23.     free.c        \
  24.     realloc.c    \
  25.     calloc.c    \
  26.     string.c    \
  27.     mlc_chk.c    \
  28.     mlc_chn.c    \
  29.     memory.c    \
  30.     tostring.c    \
  31.     m_perror.c    \
  32.     m_init.c    \
  33.     mallopt.c    \
  34.     dump.c
  35.  
  36. OBJS=    malloc.o    \
  37.     free.o        \
  38.     realloc.o    \
  39.     calloc.o    \
  40.     string.o    \
  41.     mlc_chk.o    \
  42.     mlc_chn.o    \
  43.     memory.o    \
  44.     tostring.o    \
  45.     m_perror.o    \
  46.     m_init.o    \
  47.     mallopt.o    \
  48.     dump.o
  49.  
  50. TESTS=testmlc testmem
  51.  
  52. all:    $(LIB) $(TESTS)
  53.  
  54. clean:  
  55.     rm -f $(TESTS) pgm $(LIB) *.o *.ln
  56.  
  57. sharfile:
  58.     $(SHARCMD) Makefile README patchlevel *.[ch3] 
  59.     
  60. $(LIB): $(OBJS)
  61.     ar ru $(LIB) $(OBJS)
  62.     -if test -s /bin/ranlib; then /bin/ranlib $(LIB); else exit 0; fi
  63.     -if test -s /usr/bin/ranlib; then /usr/bin/ranlib $(LIB); else exit 0; fi
  64.  
  65. testmlc:    $(LIB) testmlc.o
  66.     $(CC) -o $@ testmlc.o $(LIB)
  67.  
  68. testmem:    $(LIB) testmem.o
  69.     $(CC) -o $@ testmem.o $(LIB)
  70.  
  71. lint:    
  72.     $(LINT) $(CFLAGS) $(SRCS) testmlc.c testmem.c
  73.  
  74.  
  75. $(OBJS):    malloc.h
  76.  
  77. tostring.o malloc.o dump.o:    tostring.h
  78.